package com.itheima.String;

import java.awt.*;
import java.util.Scanner;

public class Demo08SubString {
    public static void main(String[] args) {

        Scanner sc=new Scanner(System.in);
        System.out.println("请输入手机号:");
        String s = sc.nextLine();

        String s1 = s.substring(0, 3);//截取字符串,含头不含尾
        String s2 = s.substring(s.length() - 4);
        System.out.println(s1+"****"+s2);
    }
}
